<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
</head>
<body>

<form action="/getall" method="get">
    科目：
    <input type="text" name="course" value="${course!''}"/>
    授课老师：
    <input type="text" name="tname" value="${tname!''}"/>
    <input value="查询" type="submit"/>
</form>

<table class="table" border="1" cellspacing="0" width="700px">
    <tr>
        <td>ID</td>
        <td>科目</td>
        <td>授课老师</td>
        <td>上课地点</td>
        <td>开课时间</td>
        <td>状态</td>
        <td>操作</td>
    </tr>
    <#list all.list as alla>
        <tr>
            <td>${alla.id}</td>
            <td>${alla.course}</td>
            <td>${alla.tname}</td>
            <td>${alla.site}</td>
            <td>${alla.time?date}</td>

            <#if ('${(alla.state)}'=='1')>
                <td>开课</td>
            <#elseif  ('${(alla.state)}'=='2')>
                <td>结课</td>
            </#if>

            <#--            <td>${alla.state}</td>-->

            <td><a href="/updateA?tid=${alla.id}">修改</a></td>
        </tr>


    </#list>
    <tr>
        <td colspan="7">
            <a href="/getall?page=1&size=${all.pageSize}&course=${course!''}&tname=${tname!''}">首页</a>|&lt;&lt;
            <a href="/getall?page=${all.pageNum-1}&size=${all.pageSize}&course=${course!''}&tname=${tname!''}">上一页</a>|

            <#list all.navigatepageNums   as aa>
                <#if aa==all.pageNum>
                    <a href="/getall?page=${aa}">${aa}</a>
                </#if>
                <#if  aa!=all.pageNum>
                    <a href="/getall?page=${aa}">${aa}</a>
                </#if>
            </#list>

            <a href="/getall?page=${all.pageNum+1}&size=${all.pageSize}&course=${course!''}&tname=${tname!''}">下一页</a>&gt;&gt;
            <a href="/getall?page=${all.pages}&size=${all.pageSize}&course=${course!''}&tname=${tname!''}">尾页</a>
        </td>
    </tr>
</table>
</body>
</html>